GPUs advantageously use parallel processing to efficiently perform select operations. Rendering is an example of such an operation. Rendering is the process of extracting data from world space and rendering it into a screen space. World space is three-dimensional space that is often generated from a program run on a CPU. A GPU receives instructions from the CPU program, generates the three-dimensional world space based thereon and renders a two-dimensional view for a display (i.e., screen space) from the world space. For example, the CPU program can be a video game that sends instructions to the GPU for rendering a two-dimensional view onto a display.
A GPU uses a graphics pipeline for the rendering process. Traditional graphics pipelines include fixed function units. In some conventional GPUs, programmable function stages are solely used to form a graphics pipeline or are connected with fixed function units to form a graphics pipeline. Regardless of the type of graphics pipeline, each stage modifies the input data and passes the modified data to the next stage of the pipeline for further modification to generate a view for the screen space.
Since a display view is usually a two-dimensional view, the rendering process considers depth and what a user would actually see on the display, i.e., the user's view. Ztest is a function in graphics pipelines that is used to insure what a user sees on a display are the particular objects that are supposed to be seen. Ztest is used early and late, early-Z and late-Z, in the rendering process to determine if what is currently be drawn is either in front of or behind of what is already viewable on a display in screen space.